<template>
    <div class="friend">
      <div class="site-content">
        <section-title>
          <div class="friend-header">
            <div class="title">照片</div>
          </div>
        </section-title>
        <div class="friend-list animate">
          <div class="friend-item" >
            <img  src="https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fimg.soogif.com%2FFCGoW9zPuZHmHSazSNGYbeLqRan8H4Ez.gif&refer=http%3A%2F%2Fimg.soogif.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1665133657&t=5e9b57d559dfa2d7b3e1f747e32747c5" alt="">
              <!-- <div class="site-name">11111</div>
              <div class="site-detail">1111</div> -->
          </div><div class="friend-item" >
            <img  src="https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fimg.soogif.com%2FFCGoW9zPuZHmHSazSNGYbeLqRan8H4Ez.gif&refer=http%3A%2F%2Fimg.soogif.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1665133657&t=5e9b57d559dfa2d7b3e1f747e32747c5" alt="">
              <!-- <div class="site-name">11111</div>
              <div class="site-detail">1111</div> -->
          </div><div class="friend-item" >
            <img  src="https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fimg.soogif.com%2FFCGoW9zPuZHmHSazSNGYbeLqRan8H4Ez.gif&refer=http%3A%2F%2Fimg.soogif.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1665133657&t=5e9b57d559dfa2d7b3e1f747e32747c5" alt="">
              <!-- <div class="site-name">11111</div>
              <div class="site-detail">1111</div> -->
          </div><div class="friend-item" >
            <img  src="https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fimg.soogif.com%2FFCGoW9zPuZHmHSazSNGYbeLqRan8H4Ez.gif&refer=http%3A%2F%2Fimg.soogif.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1665133657&t=5e9b57d559dfa2d7b3e1f747e32747c5" alt="">
              <!-- <div class="site-name">11111</div>
              <div class="site-detail">1111</div> -->
          </div><div class="friend-item" >
            <img  src="https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fimg.soogif.com%2FFCGoW9zPuZHmHSazSNGYbeLqRan8H4Ez.gif&refer=http%3A%2F%2Fimg.soogif.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1665133657&t=5e9b57d559dfa2d7b3e1f747e32747c5" alt="">
              <!-- <div class="site-name">11111</div>
              <div class="site-detail">1111</div> -->
          </div><div class="friend-item" >
            <img  src="https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fimg.soogif.com%2FFCGoW9zPuZHmHSazSNGYbeLqRan8H4Ez.gif&refer=http%3A%2F%2Fimg.soogif.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1665133657&t=5e9b57d559dfa2d7b3e1f747e32747c5" alt="">
              <!-- <div class="site-name">11111</div>
              <div class="site-detail">1111</div> -->
          </div><div class="friend-item" >
            <img  src="https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fimg.soogif.com%2FFCGoW9zPuZHmHSazSNGYbeLqRan8H4Ez.gif&refer=http%3A%2F%2Fimg.soogif.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1665133657&t=5e9b57d559dfa2d7b3e1f747e32747c5" alt="">
              <!-- <div class="site-name">11111</div>
              <div class="site-detail">1111</div> -->
          </div><div class="friend-item" >
            <img  src="https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fimg.soogif.com%2FFCGoW9zPuZHmHSazSNGYbeLqRan8H4Ez.gif&refer=http%3A%2F%2Fimg.soogif.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1665133657&t=5e9b57d559dfa2d7b3e1f747e32747c5" alt="">
              <!-- <div class="site-name">11111</div>
              <div class="site-detail">1111</div> -->
          </div>
        </div>
      </div>
    </div>
  </template>
  
  <script>
  import sectionTitle from "@/components/section-title";
  import Quote from "@/components/quote";
  import { fetchFriend } from "../api";
  export default {
    name: "Friend",
    data() {
      return {
        websiteInfo: {},
        list: [],
      };
    },
    components: {
      Quote,
      sectionTitle,
    },
    methods: {
  
      fetchFriend() {
        fetchFriend()
          .then((res) => {
            this.list = res.data || [];
          })
          .catch((err) => {
            console.log(err);
          });
      },
      getWebSiteInfo() {
        this.$store.dispatch("getSiteInfo").then((data) => {
          this.websiteInfo = data;
        });
      },
    },
    mounted() {
      this.getWebSiteInfo();
      this.fetchFriend();
    },
  };
  </script>
  
  <style scoped lang="less">

img {
                width: 220px;
                height: 130px;
                object-fit: cover;
                border-radius: 5%;
                padding: 2px;
                border: 1px solid #DADADA;
                position: relative;
                transition: all 0.2s linear;
                overflow: hidden;
                &:hover {
                    transform: scale(1.1, 1.1);
                    filter: contrast(130%);
                }
            }
  .friend {
    padding-top: 40px;
  }
  .friend-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 80px;
    font-weight: 400;
    .title {
      font-size: 20px;
    }
    .apply:hover {
      color: #ff6d6d;
    }
  }
  .statement {
    margin: 60px 0 20px 0;
    a {
      color: #ff6d6d;
    }
    p {
      line-height: 2rem;
    }
  }
  hr {
    margin: 40px 0;
    border: 0;
    height: 1px;
    background-image: linear-gradient(
      to right,
      rgba(0, 0, 0, 0),
      rgba(255, 109, 109, 0.75),
      rgba(0, 0, 0, 0)
    );
  }
  .friend-list {
    width: 100%;
    .friend-item {
      display: inline-block;
      width: 30%;
      /*height: 100px;*/
      margin: 0 5% 20px 0;
      padding: 0px 0px;
    //   border: 1px solid #ececec;
      border-radius: 3px;
    //   &:hover {
    //     box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
    //   }
      &:nth-of-type(3n) {
        margin-right: 0;
      }
      .site-name,
      .site-detail {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        padding-bottom: 10px;
        line-height: 1.5rem;
      }
      .site-name {
        color: #8fd0cc;
        border-bottom: 1px dotted #ececec;
      }
      .site-detail {
        font-size: 13px;
        padding-top: 10px;
      }
    }
  }
  /*******/
  @media (max-width: 800px) {
    .friend-header {
      margin-top: 0;
    }
    .friend-list {
      .friend-item {
        width: 45%;
        &:nth-of-type(2n) {
          margin-right: 0;
        }
        &:nth-of-type(3n) {
          margin-right: 5%;
        }
      }
    }
  }
//   @media (max-width: 600px) {
//     .friend-list {
//       .friend-item {
//         display: block;
//         width: 90%;
//         margin: 0 auto 20px auto;
//         &:nth-of-type(2n) {
//           margin-right: auto;
//         }
//         &:nth-of-type(3n) {
//           margin-right: auto;
//         }
//       }
//     }
//   }
  
  
  </style>
  